package com.znf4.controller.user.dto;
/*package com.znf4.platform.controller.user;

import java.math.BigDecimal;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import com.znf4.platform.account.entity.RpAccount;
import com.znf4.platform.account.entity.RpAccountHistory;
import com.znf4.platform.account.enums.AccountFundDirectionEnum;
import com.znf4.platform.account.service.RpAccountHistoryService;
import com.znf4.platform.account.service.RpAccountInAndOutRecordService;
import com.znf4.platform.account.service.RpAccountService;
import com.znf4.platform.account.vo.SettAmountVo;
import com.znf4.platform.bank.entity.RemitBankInfo;
import com.znf4.platform.bank.entity.RemitBankType;
import com.znf4.platform.bank.enums.BankWayEnum;
import com.znf4.platform.banklink.vo.ProxyPayResult;
import com.znf4.platform.common.core.config.BusinessConfig;
import com.znf4.platform.common.core.dwz.DWZ;
import com.znf4.platform.common.core.dwz.DwzAjax;
import com.znf4.platform.common.core.enums.BankCardAuditEnum;
import com.znf4.platform.common.core.enums.PublicEnum;
import com.znf4.platform.common.core.enums.PublicStatusEnum;
import com.znf4.platform.common.core.enums.SecurityRatingEnum;
import com.znf4.platform.common.core.enums.UserTypeEnum;
import com.znf4.platform.common.core.exception.BizException;
import com.znf4.platform.common.core.page.PageBean;
import com.znf4.platform.common.core.page.PageParam;
import com.znf4.platform.common.core.utils.StringUtil;
import com.znf4.platform.controller.common.BaseController;
import com.znf4.platform.controller.user.dto.UserDTO;
import com.znf4.platform.permission.controller.PmsRoleController;
import com.znf4.platform.permission.entity.PmsRole;
import com.znf4.platform.trade.exception.TradeBizException;
import com.znf4.platform.trade.service.RpTradePaymentManagerService;
import com.znf4.platform.user.entity.RpUserBankAccount;
import com.znf4.platform.user.entity.RpUserBankCard;
import com.znf4.platform.user.entity.RpUserInfo;
import com.znf4.platform.user.entity.RpUserPayConfig;
import com.znf4.platform.user.enums.BankAccountTypeEnum;
import com.znf4.platform.user.enums.BankCodeEnum;
import com.znf4.platform.user.exception.UserBizException;
import com.znf4.platform.user.service.RpUserBankAccountService;
import com.znf4.platform.user.service.RpUserBankCardService;
import com.znf4.platform.user.service.RpUserInfoService;
import com.znf4.platform.user.service.RpUserPayConfigService;

*//**
 * 账户信息 
 *//*
@Controller
@RequestMapping("/user/bankAccount")
public class UserBankAccountController extends BaseController{
	
	@Autowired
	private RpUserBankAccountService rpUserBankAccountService;
	
	@Autowired
	private RpUserBankCardService rpUserBankCardService;

	private static Log log = LogFactory.getLog(UserBankAccountController.class);
	
	*//**
	 * 函数功能说明 ： 查询商户设置默认的银行信息
	 *
	 * @参数： @return
	 * @return String
	 * @throws
	 *//*
	@RequestMapping(value = "/defaultList", method = { RequestMethod.POST, RequestMethod.GET })
	public String defaultList(RpUserBankAccount rpUserBankAccount, PageParam pageParam, Model model) {
		Map<String,Object> paramMap = new HashMap<>();
		rpUserBankAccount.setStatus(PublicStatusEnum.ACTIVE.name());//激活的
		paramMap.put("rpUserBankAccount", rpUserBankAccount);
		PageBean pageBean = rpUserBankAccountService.listPage(pageParam,paramMap);
		model.addAttribute("pageBean", pageBean);
		return "user/bankAccount/defaultList";
	}
	
	*//**
	 * 函数功能说明 ： 查询商户待审核的银行账户信息
	 *
	 * @参数： @return
	 * @return String
	 * @throws
	 *//*
	@RequestMapping(value = "/waitConfirmList", method = { RequestMethod.POST, RequestMethod.GET })
	public String waitConfirmList(RpUserBankCard rpUserBankCard, PageParam pageParam, Model model) {
		Map<String,Object> paramMap = new HashMap<>();
		rpUserBankCard.setStatus(PublicStatusEnum.ACTIVE.name());             //激活的
		rpUserBankCard.setIsAudit(BankCardAuditEnum.WAIT_CONFIRM.name());
		paramMap.put("rpUserBankCard", rpUserBankCard);
		PageBean pageBean = rpUserBankCardService.listPage(pageParam,paramMap);
		model.addAttribute("pageBean", pageBean);
		return "user/bankAccount/waitConfirmList";
	}
	*//**
	 * 函数功能说明 ： 查询商户已审核通过的银行账户信息
	 *
	 * @参数： @return
	 * @return String
	 * @throws
	 *//*
	@RequestMapping(value = "/confirmedList", method = { RequestMethod.POST, RequestMethod.GET })
	public String confirmedList(RpUserBankCard rpUserBankCard, PageParam pageParam, Model model) {
		Map<String,Object> paramMap = new HashMap<>();
		rpUserBankCard.setStatus(PublicStatusEnum.ACTIVE.name());          //激活的
		rpUserBankCard.setIsAudit(BankCardAuditEnum.CONFIRMED.name());//已审核
		paramMap.put("rpUserBankCard", rpUserBankCard);
		PageBean pageBean = rpUserBankCardService.listPage(pageParam,paramMap);
		model.addAttribute("pageBean", pageBean);
		return "user/bankAccount/confirmedList";
	}
	
	*//**
	 * 函数功能说明 ： 查询所有商户银行账户信息
	 *
	 * @参数： @return
	 * @return String
	 * @throws
	 *//*
	@RequestMapping(value = "/list", method = { RequestMethod.POST, RequestMethod.GET })
	public String list(RpUserBankCard rpUserBankCard, PageParam pageParam, Model model) {
		Map<String,Object> paramMap = new HashMap<>();
		rpUserBankCard.setStatus(PublicStatusEnum.ACTIVE.name());          //激活的
		paramMap.put("rpUserBankCard", rpUserBankCard);
		PageBean pageBean = rpUserBankCardService.listPage(pageParam,paramMap);
		model.addAttribute("pageBean", pageBean);
		return "user/bankAccount/list";
	}
	
	*//**
	 * 函数功能说明 ： 查询已删除的商户银行账户信息
	 *
	 * @参数： @return
	 * @return String
	 * @throws
	 *//*
	@RequestMapping(value = "/deleteList", method = { RequestMethod.POST, RequestMethod.GET })
	public String deleteList(RpUserBankCard rpUserBankCard, PageParam pageParam, Model model) {
		Map<String,Object> paramMap = new HashMap<>();
		rpUserBankCard.setStatus(PublicStatusEnum.UNACTIVE.name());         //删除条件
		paramMap.put("rpUserBankCard", rpUserBankCard);
		PageBean pageBean = rpUserBankCardService.listPage(pageParam,paramMap);
		model.addAttribute("pageBean", pageBean);
		return "user/bankAccount/deleteList";
	}

	*//**
	 * 函数功能说明 ： 修改审核状态
	 * 
	 * @参数： @return
	 * @return String
	 * @throws
	 *//*
	//@RequiresPermissions("user:bankAccount:auditEdit")
	*//**
	 * @param request
	 * @param model
	 * @param rpUserBankAccount
	 * @param dwz
	 * @return
	 *//*
	@RequestMapping(value = "/auditEdit", method = { RequestMethod.POST, RequestMethod.GET })
	public String auditEdit(HttpServletRequest request,Model model,RpUserBankCard rpUserBankCard,DwzAjax dwz) {
		String userNo = rpUserBankCard.getUserNo();
		String bankAccountNo = rpUserBankCard.getBankAccountNo();
		String isAudit = rpUserBankCard.getIsAudit();
		RpUserBankCard bankCard = rpUserBankCardService.getByUserNoAndBankCardNo(userNo, bankAccountNo);
		bankCard.setIsAudit(isAudit);
		try {
			rpUserBankCardService.updateData(bankCard);
			dwz.setNavTabId("dshyhzh");
			return operateSuccess(model, dwz);
		} catch (Exception e) {
			log.error("== auditEdit exception:", e);
			dwz.setNavTabId("dshyhzh");
			return operateError("审核操作失败", model);
		}
	}

	*//**
	 * 函数功能说明 ： 删除账户信息
	 * 
	 * @参数： @return
	 * @return String
	 * @throws
	 *//*
	//@RequiresPermissions("user:bankAccount:delete")
	@RequestMapping(value = "/delete", method = { RequestMethod.POST, RequestMethod.GET })
	public String delete(HttpServletRequest request,Model model,RpUserBankAccount rpUserBankCard,DwzAjax dwz) {
		String userNo = rpUserBankCard.getUserNo();
		String bankAccountNo = rpUserBankCard.getBankAccountNo();
		String status = PublicStatusEnum.UNACTIVE.name();
		RpUserBankCard bankCard = rpUserBankCardService.getByUserNoAndBankCardNo(userNo, bankAccountNo);
		if(bankCard.getIsDefault().equals("YES")) {
			return operateError("银行账户为默认账户，无法删除", model);
		}
		if(bankCard.getIsAudit().equals("WAIT_CONFIRM")) {
			return operateError("银行账户正在审核中，无法删除", model);
		}
		else {
			try {
				bankCard.setStatus(status);//删除
				rpUserBankCardService.updateData(bankCard);
				dwz.setNavTabId("yhzhlb");
				return operateSuccess(model, dwz);
			} catch (Exception e) {
				log.error("== deleteBankAccount exception:", e);
				dwz.setNavTabId("yhzhlb");
				return operateError("删除失败", model);
			}
		}
	}
}
*/